#include<bits/stdc++.h>
using namespace std;
const int N = 1e4 + 10;
int a1[N] , b1[N] , a2[N] , b2[N];
int t1 , t2;
string s;
int check(int a , int b , int pt){
	if(a < pt && b < pt) return 0;
	if(a >= b + 2 || a <= b - 2) return 1;
	return 0;
} 
int main(){
	freopen("table.in" , "r" , stdin);
	freopen("table.out" , "w" , stdout);
	t1 = 1 , t2 = 1;
	while(cin >> s){
		int len = s.size();
		for(int i = 0 ; i < len ; i++){
			if(s[i] == 'W'){
				a1[t1]++;
				a2[t2]++;
			}
			if(s[i] == 'L'){
				b1[t1]++;
				b2[t2]++;
			}
			if(check(a1[t1] , b1[t1] , 11)) t1++;
			if(check(a2[t2] , b2[t2] , 21)) t2++;
			if(s[i] == 'E') break;
		}
	}
	for(int i = 1 ; i <= t1 ; i++){
		cout << a1[i] << ":" << b1[i] << endl;
	}
	cout << endl;
	for(int i = 1 ; i <= t2 ; i++){
		cout << a2[i] << ":" << b2[i] << endl;
	}
	return 0;
}
